﻿@{
    //Layout = null;
    Layout = "~/Views/Shared/MainLayout.cshtml";
    ViewBag.Title = "修改";
}
@model Model.Content
@*<!DOCTYPE html>

<html>
<head>
    <meta name="viewport" content="width=device-width" />
    <link href="~/Content/bootstrap.css" rel="stylesheet" />
    
    <script src="~/Scripts/bootstrap.js"></script>
    <title>修改</title>
    
</head>
<body>
    <div class="container">
        <br />
        
    </div>
</body>
</html>*@
<link href="~/Content/KindEditor/themes/default/default.css" rel="stylesheet" />
<script src="~/Scripts/KindEditor/kindeditor.js"></script>
<script src="~/Scripts/KindEditor/lang/zh_CN.js"></script>
@*<script src="~/Scripts/jquery-2.1.4.js"></script>*@

@*上传*@
@*<script src="~/Scripts/upload/jquery-ui-1.9.2.js"></script>
<script src="~/Scripts/upload/jquery.fileupload.js"></script>
<script src="~/Scripts/upload/EditorPortal/jquery.hexstudy.upload.js"></script>*@
@*load*@
@*<script src="~/Scripts/Loading.js"></script>*@

<script>
    KindEditor.ready(function (K) {
        window.editor = K.create('#editor_id',
            {
                uploadJson: '/Upload/Index',
                //fileManagerJson: '/FileProcess/DownLoad/1',  //文件空间管理
                allowFileManager: true,
                filterMode: false,
                items: [
    'source', '|', 'undo', 'redo', '|', 'preview', 'print', 'template', 'code', 'cut', 'copy', 'paste',
    'plainpaste', 'wordpaste', '|', 'justifyleft', 'justifycenter', 'justifyright',
    'justifyfull', 'insertorderedlist', 'insertunorderedlist', 'indent', 'outdent', 'subscript',
    'superscript', 'clearhtml', 'quickformat', 'selectall', '|', 'fullscreen', '/',
    'formatblock', 'fontname', 'fontsize', '|', 'forecolor', 'hilitecolor', 'bold',
    'italic', 'underline', 'strikethrough', 'lineheight', 'removeformat', '|', 'image', 'multiimage',
    'flash', 'media', 'insertfile', 'table', 'hr', 'emoticons', 'baidumap', 'pagebreak',
    'anchor', 'link', 'unlink', '|', 'about'
                ]
            });
    });
</script>

@using (Html.BeginForm("Update", "Read", FormMethod.Post, new { @class = "form-horizontal", ENCTYPE = "multipart/form-data" }))
{
    <div class="row">
        <div class="col-md-1">
            <span>标题</span>
        </div>
        <div class="col-md-6">
            <input type="text" name="title" value="@Model.Title" class="form-control" />
        </div>
        <div class="col-md-5"></div>
    </div>
    <br />
    <div class="row">
        <div class="col-md-1">
            <span>缩略图</span>
        </div>
        <div class="col-md-3">
            <img style="width:100px;height:100px;" src="/FileProcess/DownLoad/@Model.Cover" />
        </div>
        <div class="col-md-3">
            <input id="btn_cover" type="file" class="btn btn-primary form-control" name="imgFile" />
            <input type="hidden" id="Cover" />
        </div>
        <div class="col-md-5">
            @*<input type="file" id="fileupload_cover" name="file" accept="image/gif,image/jpeg,image/bmp,image/png,image/ico,image/jpg" multiple="multiple" style="display: none">
            <img id="img_cover" src="" style="width:100px;height:100px;" target="" />*@
        </div>
    </div>
    <br />
    <div class="row">
        <div class="col-md-12">
            <textarea id="editor_id" name="Contents" style="width:100%;height:500px;">@Model.Contents</textarea>
        </div>
    </div>
    <br />
    <div class="row">
        <div class="col-md-11"></div>
        <div class="col-md-1">
            <input type="hidden" value="@Model.CategoryId" name="CategoryId" />
            <input type="hidden" name="ContentId" value="@Model.ContentId" />
            <input type="submit" class="btn btn-primary" value="提交" />
        </div>
    </div>
}
<script type="text/javascript">
    
</script>